package com.lzh.edu.client;

import com.lzh.commonutils.CommonResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@Component
//调用服务的名称
@FeignClient(name = "service-vod",fallback = VodFileFeignClient.class)
public interface VodClient {
    /**
     * 调用远程服务删除单个视频
     * 路径是远程服务的请求路径
     * @param videoId 视频文件id
     * @return
     */
    @DeleteMapping("/eduVod/removeAliyunVodById")
    public CommonResult removeVideo(@RequestParam("videoId") String videoId);

    /**
     * 调用远程服务批量删除视频
     * @param videoList 视频文件id集合
     * @return
     */
    @DeleteMapping("/eduVod/removeAliyunVodBatch")
    public CommonResult removeBatchVideo(@RequestParam("videoList") List<String> videoList);
}
